﻿<%@ Page Title="" Language="C#" MasterPageFile="~/ModulesPage.Master" AutoEventWireup="true" CodeBehind="DutiesCreation.aspx.cs" Inherits="SwenAssignment3.HousekeepingManagementModule.DutiesCreation" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>


<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <link href="ModulePage.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
        .auto-style1 {
            width: 100%;
        }
        .auto-style2 {
            height: 24px;
        }
        .auto-style3
        {
            height: 22px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder2" runat="server">
    <table class="auto-style1">
        <tr>
            <td>Duty:</td>
            <td>
                <asp:TextBox ID="tbxDuty" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="tbxDuty" ErrorMessage="Please enter the name of the duty" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td>&nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td class="auto-style3">Start Date:</td>
            <td class="auto-style3">
                <asp:TextBox ID="tbxStartDate" runat="server"></asp:TextBox>
                <asp:CalendarExtender ID="tbxStartDate_CalendarExtender" runat="server" Enabled="True" TargetControlID="tbxStartDate">
                </asp:CalendarExtender>
                <asp:RangeValidator ID="RangeValidator1" runat="server" ErrorMessage="Please enter a proper date" ForeColor="Red"  Type="Date" Display="Dynamic" ControlToValidate="tbxStartDate"></asp:RangeValidator>
            &nbsp;<asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="tbxStartDate" ControlToValidate="tbxEndDate"  Display="Dynamic"  ErrorMessage="Start date shouldn't be greater than end date" Operator="GreaterThanEqual" ForeColor="Red"></asp:CompareValidator>
            </td>
        </tr>
        <tr>
            <td class="auto-style3">&nbsp;</td>
            <td class="auto-style3">
                &nbsp;</td>
        </tr>
        <tr>
            <td>End Date:</td>
            <td>
                <asp:TextBox ID="tbxEndDate" runat="server"></asp:TextBox>
                <asp:CalendarExtender ID="tbxEndDate_CalendarExtender" runat="server" Enabled="True" TargetControlID="tbxEndDate">
                </asp:CalendarExtender>
                <asp:RangeValidator ID="RangeValidator2" runat="server" ErrorMessage="Please enter a proper date" ForeColor="Red" ControlToValidate="tbxEndDate"  Type="Date" Display="Dynamic"></asp:RangeValidator>
            &nbsp;<asp:CompareValidator ID="CompareValidator2" runat="server" ControlToCompare="tbxEndDate" ControlToValidate="tbxStartDate" ErrorMessage=" End date shouldn't be greater than start date" Operator="GreaterThanEqual" ForeColor="Red"></asp:CompareValidator>
            </td>
        </tr>
        <tr>
            <td>&nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td class="auto-style2">Description:</td>
            <td class="auto-style2">
                <asp:TextBox ID="tbxDescription" runat="server" Height="90px" TextMode="MultiLine" Width="249px"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="auto-style2">&nbsp;</td>
            <td class="auto-style2">
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <asp:ImageButton ID="ImageButton1" runat="server" Height="42px" ImageUrl="~/Pictures/CreateButton1.png" OnClick="ImageButton1_Click" Width="72px" />
&nbsp;<asp:ImageButton ID="ImageButton2" runat="server" Height="45px" ImageUrl="~/Pictures/BackButton1.png" OnClientClick="history.back()" Width="69px" />
            </td>
        </tr>
    </table>
</asp:Content>
